import request from '@/router/axios';
import {baseUrl} from '@/config/env';

export const listGen= (data) => request({
    url: baseUrl + '/sys/generator/page',
    method: 'post',
    data: data
});

export const listTablePage= (data) => request({
    url: baseUrl + '/sys/generator/tablePage',
    method: 'post',
    data: data
});
export const addGen = (data) => request({
    url: baseUrl + '/sys/generator',
    method: 'post',
    data: data
});
export const execute = (data) => request({
    url: baseUrl + '/sys/generator/execute',
    method: 'post',
    data: data
});
export const synchro = (id) => request({
    url: baseUrl + '/sys/generator/'+id+'/synchro',
    method: 'get',
});

export const delGen = (ids) => request({
    url: baseUrl + '/sys/generator/' + ids,
    method: 'delete',
});
export const updateGen = (data) => request({
    url: baseUrl + '/sys/generator',
    method: 'put',
    data: data
});

